const mongoose = require('mongoose')
const {Schema,model} = mongoose 
const commonSchema = new Schema({
  __v : {type: Number,select:false},
  blogId:{type: String, required: true},
  common:{type: [{
    uid: {type: String, required: true},
    realname: {type: String, required: true},
    avatar_url: {type: String, required: true},
    content: {type: String, required: true},
    time: {type: String, required: false},
    isDelete: {type: Boolean,default:false, required: false},
  }]} // 评论列表  列表每个元素为 用户id 和 该用户说的话
},{timestamps:true})

module.exports = model("Common",commonSchema) 